package com.easy.dfc.service;

import com.easy.dfc.Utils.PagingUtil;
import com.easy.dfc.mapper.FollowproductMapper;
import com.easy.dfc.mapper.ProductsetMapper;
import com.easy.dfc.entity.Followproduct;
import com.easy.dfc.entity.ProductsetWithBLOBs;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * Created by VULCANTSeries on 2017/5/15.
 */
@Service
public class FollowProductService {

    @Resource
    private FollowproductMapper followproductMapper;

    @Resource
    private ProductsetMapper productsetMapper;

    public int insertSelective(Followproduct record) {
        return followproductMapper.insertSelective(record);
    }

    public Followproduct selectFollow(Followproduct followproduct) {
        return followproductMapper.selectFollow(followproduct);
    }

    public int deleteByPrimaryKey(int id) {
        return followproductMapper.deleteByPrimaryKey(id);
    }

    public int deleteOne(Followproduct followproduct) {
        return followproductMapper.deleteOne(followproduct);
    }

    public List<ProductsetWithBLOBs> selectFollowProduct(PagingUtil pagingUtil) {
        return productsetMapper.selectFollowProduct(pagingUtil);
    }
}
